﻿$(document).on("pageInit", "#page-main", function (e, id, page) {
    console.log(1);
    $(page).find("#menu-btn").on("click", function () {
        var buttons1 = [
 {
     text: '请选择',
     label: true
 },
 {
     text: '创建请假申请',
     bold: true,
     onClick: function () {
         $.router.load('/apply/create', true);
     }
 },
 {
     text: '退出登录',
     onClick: function () {
         location.href = "/account/logout";
     }
 }];

        var buttons2 = [
          {
              text: '取消',
              bg: 'danger'
          }
        ];
        var groups = [buttons1, buttons2];
        $.actions(groups);
    });
});